// 邮箱正则校验
export function validEmail (email) {
  const reg = /^[A-Za-z\d]+([-_.][A-Za-z\d]+)*@([A-Za-z\d]+[-.])+[A-Za-z\d]{2,5}$/
  return reg.test(email)
}

// 密码正则校验
export function validPassword (password) {
  const reg = /^(?=.*\d)(?=.*[a-z])[a-zA-Z0-9]{6,12}$/
  return reg.test(password)
}

// 手机正则校验
export function validTelephone (telephone) {
  const reg = /^1[3456789]\d{9}$/
  return reg.test(telephone)
}
